<?php
/**
 * Yar RPC 客户端
 *
 * @link https://www.php.net/manual/zh/class.yar-client.php
 */
class Yar_Client
{

    protected $_protocol;

    protected $_uri;

    protected $_options;

    protected $_running;

    /**
     * 创建一个客户端实例
     *
     * @param string $uri
     * @param array|NULL $options
     * @link https://www.php.net/manual/zh/yar-client.construct.php
     */
    public function __construct(string $uri, array $options = NULL) {}

    /**
     * 调用远程服务
     *
     * @param string $method
     * @param array $arguments
     * @return mixed
     * @link https://www.php.net/manual/zh/yar-client.call.php
     */
    public function call(string $method, array $arguments):mixed {}

    /**
     * 获取调用的配置
     *
     * @param int $type
     * @return mixed
     * @link https://www.php.net/manual/zh/yar-client.getopt.php
     */
    public function getOpt(int $type):mixed {}

    /**
     * 设置调用的配置
     *
     * @param int $type
     * @param mixed $value
     * @return Yar_Client|bool
     * @link https://www.php.net/manual/zh/yar-client.setopt.php
     */
    public function setOpt(int $type, mixed $value):Yar_Client|bool {}

    /**
     * 调用远程服务
     *
     * @implementation-alias Yar_Client::call
     * @link https://www.php.net/manual/zh/yar-client.call.php
     */
    public function __call(string $method, array $arguments):mixed {}
}
